﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Telerik.Web.UI;

namespace BSCMFF.Web.UserControls.Ratings
{
    public partial class RatingBar : System.Web.UI.UserControl
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            //RadRating rt
        }

        public bool RBEnabled 
        {
            get
            {
                return ratingBar.Enabled;
            }
            set
            {
                ratingBar.Enabled = value;
            }
        }

        public int? DbValue
        {
            get
            {
                return Convert.ToInt32(ratingBar.DbValue);
            }
            set
            {
                //if (value == null)
                //{
                //    ratingBar.Value = 0;
                //}
                //else
                //{
                    ratingBar.DbValue = Convert.ToDecimal(value);
                //}
            }
        }

        //public RadRating MyProperty
        //{
        //    get
        //    {
        //        return ratingBar;
        //    }
        //    set
        //    {
        //        ratingBar = value;
        //    }
        //}
    }
}